# -*- coding:utf-8 *-
# 项目       :    易聊测试 
# 文件       :    create_user.py
# 作者       :    zc 
# 时间       :    2021/9/24  2:05 下午 
# IDE       :    PyCharm

import requests

headers2 = {'Content-Type': 'application/json;charset=UTF-8','Cookie':'JSESSIONID=948D4794DA63027487E774368FDB3BD1; Admin-Token=eyJhbGciOiJSUzI1NiJ9.eyJzdWIiOiLmmJPogYrnp5HmioAiLCJpc3MiOiLmmJPogYrnp5HmioAiLCJpYXQiOjE2MzI0NjMzNzIsImV4cCI6MTYzMjU0OTc3MiwiY29tcGFueUlkIjoxLCJ1c2VySWQiOiJkZXYtemMiLCJkZXBhcnRtZW50SWQiOjE0MzQ1LCJnZW5lcmF0ZVRpbWUiOiIyMDIxLTA5LTI0IDE0OjAyOjUyIiwianRpIjoiNzM1NDBmN2MtMWMxNS00YTJmLWFjZjAtMGNjOTVjZDk0ZmExIn0.bmtg2581HxIq5wD2Wrh3APxECNhUmjbmoUPhQyW_nGwkwqNpAg02OSIAYpmdgV0TrO7G7ntT2Vpp5Ihok3-g8qZWKhXRSw0rwJh--69etBU98FYrMwsOEX20wuaBkbs0SditifTvpHiN1FDFjPlmOTrEWttVftDVghF81UAPdrc; comeFrom=10000',
            'Authorization':'eyJhbGciOiJSUzI1NiJ9.eyJzdWIiOiLmmJPogYrnp5HmioAiLCJpc3MiOiLmmJPogYrnp5HmioAiLCJpYXQiOjE2MzI0NjMzNzIsImV4cCI6MTYzMjU0OTc3MiwiY29tcGFueUlkIjoxLCJ1c2VySWQiOiJkZXYtemMiLCJkZXBhcnRtZW50SWQiOjE0MzQ1LCJnZW5lcmF0ZVRpbWUiOiIyMDIxLTA5LTI0IDE0OjAyOjUyIiwianRpIjoiNzM1NDBmN2MtMWMxNS00YTJmLWFjZjAtMGNjOTVjZDk0ZmExIn0.bmtg2581HxIq5wD2Wrh3APxECNhUmjbmoUPhQyW_nGwkwqNpAg02OSIAYpmdgV0TrO7G7ntT2Vpp5Ihok3-g8qZWKhXRSw0rwJh--69etBU98FYrMwsOEX20wuaBkbs0SditifTvpHiN1FDFjPlmOTrEWttVftDVghF81UAPdrc',
            'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/93.0.4577.82 Safari/537.36'
            }

url = "http://dev-app.easyliao.com/auth-eupms/customer/add"
data ={"userId":"dev-test3",
       "userNo":"dev-test3",
       "userName":"dev-test3",
       "pubName":"dev-test3",
       "loginStartTime":"",
       "loginEndTime":"",
       "userRoleDetails":[{"roleUid":"c8702ae3c98642e0b25acc0f7af2f38c"}],
       "mail":"","qq":"","mobilePhone":"","phone":"","departmentId":21543,"maxServiceNum":0,"maxChatNum":0,"grade":1,
       "ip":"","mac":"","headUrl":"","sipNumber":"","sipKey":"","sipServer":"","sipDomain":"","remark":"",
       }

res = requests.post(url,data=data,headers=headers2)

print(res.text)